package com.tju.ocean_ecology_website.dto;

import lombok.Data;

/**
 * 志愿者查询DTO
 */
@Data
public class VolunteerQueryDTO {
    private Integer page = 1;
    private Integer pageSize = 10;
    private String username;
    private String realName;
    private String name;
    private Integer status;
    
    /**
     * 转换为PageRequest对象
     */
    public org.springframework.data.domain.PageRequest toPageRequest() {
        return org.springframework.data.domain.PageRequest.of(page - 1, pageSize);
    }
}
